package cn.demo.service1.client;

import cn.demo.service1.client.fallback.factory.Service0FallbackFactory;
import cn.demo.service1.config.FeignConfiguration;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @Author: liujiahao
 * @Description:
 */
@FeignClient(name = "consumer",fallbackFactory = Service0FallbackFactory.class,configuration = FeignConfiguration.class)
public interface Service0Client {

    @RequestMapping(method = RequestMethod.GET, path = "user/{userId}/{sleepSec}")
    String test(
            @PathVariable("userId") String userId,
            @PathVariable("sleepSec") int sleepSec
    );


    @RequestMapping(
            method = RequestMethod.GET,
            path = "pro"
    )
    String pro(

    );
}
